<?php

class Example_Controller_Page
    extends Example_Controller
{

    public function __construct(array $args = array( ))
    {
        $main = new Example_Element_Site_Main(array(
            'contents' => array(

                'nav_above' => null,

                'title' => null,

                'loop' => new OOWP_Loop(array(
                    'article_class' => 'Example_Element_Article_Page',
                )),

                'nav_below' => null,

            ),
        ));

        $input = array_merge(array(
            'body' => new Example_Element_Site_Body(array(
                'contents' => array(
                    'main' => $main,
                ),
            )),
        ), $args);

        parent::__construct($input);
    }

    public static function matches(WP_Query $query)
    {
        if ($query->is_page) {
            return true;
        }
        return false;
    }

}
